#include "spectrumprivatedefine.h"


namespace DataSpecificationGW
{
    SpectrumHeadPrivate::SpectrumHeadPrivate()
    {
        ucSpectrumTypeCode = 0;
        bSkipeSpectrumTypeCode = false;
        bHaseSpectrumTypeCode = false;

        iSpectrumDataLength = 0;
        bSkipSpectrumDataLength = false;
        bHasSpectrumDataLength = false;

        qstrSpectrumGenerationTime = "";
        bSkipSpectrumGenerationTime = false;
        bHasSpectrumGenerationTime = false;

        ucSpectrumCharacter = 1;
        bSkipSpectrumCharacter = false;
        bHasSpectrumCharacter = false;

        qstrEquipmentName = "";
        bSkipEquipmentName = false;
        bHasEquipmentName = false;

        qstrEquipmentCode = "";
        bSkipEquipmentCode = false;
        bHasEquipmentCode = false;

        qstrTestPointName = "";
        bSkipTestPointName = false;
        bHasTestPointName = false;

        qstrTestPointCode = "";
        bSkipTestPointCode = false;
        bHasTestPointCode = false;

        sDetectionChannelID = 0;
        bSkipDetectionChannelID = false;
        bHasDetectionChannelID = false;

        ucStorageDataType = 6;
        bSkipStorageDataType = false;
        bHasStorageDataType = false;
    }

    SpectrumHeadPrivate& SpectrumHeadPrivate::operator=(const SpectrumHeadPrivate& obj_val)
    {
        this->ucSpectrumTypeCode = obj_val.ucSpectrumTypeCode;
        this->iSpectrumDataLength = obj_val.iSpectrumDataLength;
        this->qstrSpectrumGenerationTime = obj_val.qstrSpectrumGenerationTime;
        this->ucSpectrumCharacter = obj_val.ucSpectrumCharacter;
        this->qstrEquipmentName = obj_val.qstrEquipmentName;
        this->qstrEquipmentCode = obj_val.qstrEquipmentCode;
        this->qstrTestPointName = obj_val.qstrTestPointName;
        this->qstrTestPointCode = obj_val.qstrTestPointCode;
        this->sDetectionChannelID = obj_val.sDetectionChannelID;
        this->ucStorageDataType = obj_val.ucStorageDataType;
        return *this;
    }

    bool SpectrumHeadPrivate::operator==(const SpectrumHeadPrivate& obj_val) const
    {
        if (!(this->ucSpectrumTypeCode == obj_val.ucSpectrumTypeCode)) return false;
        if (!(this->iSpectrumDataLength == obj_val.iSpectrumDataLength)) return false;
        if (!(this->qstrSpectrumGenerationTime == obj_val.qstrSpectrumGenerationTime)) return false;
        if (!(this->ucSpectrumCharacter == obj_val.ucSpectrumCharacter)) return false;
        if (!(this->qstrEquipmentName == obj_val.qstrEquipmentName)) return false;
        if (!(this->qstrEquipmentCode == obj_val.qstrEquipmentCode)) return false;
        if (!(this->qstrTestPointName == obj_val.qstrTestPointName)) return false;
        if (!(this->qstrTestPointCode == obj_val.qstrTestPointCode)) return false;
        if (!(this->sDetectionChannelID == obj_val.sDetectionChannelID)) return false;
        if (!(this->ucStorageDataType == obj_val.ucStorageDataType)) return false;
        return true;
    }
}
